/**
 * 
 */
package org.cuatrovientos.es;

import java.util.Scanner;



/**
 * @author Beatriz
 *
 */
public class Main {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		
		
		
		String[] array = new String[101];
				
		List.emptyArray(array); 
				
		String line = ""; 
				
		Scanner reader = new Scanner(System.in);
				
						
				do {
					
					List.mostrarMenu();
				
					line = reader.nextLine();
					int option = Integer.parseInt(line);
											
					switch (option) {
					case 1: List.showList(array);
						break;
					case 2: 
						System.out.println("Write which element you want to add");
						String value = "";
						value = reader.nextLine();
						List.insertElement(array, value);
						break;
					case 3: 
						System.out.println("Write the position on the list you want to erase");
						line = reader.nextLine();
						List.eraseElement(array, Integer.parseInt(line));
						break;
					default: 
						break;
					}
				
				} while (Integer.parseInt(line) != 4); 
	}

}
